package heima3_2.cn.osc.presenter;

import java.util.List;

import heima3_2.cn.osc.base.OurTabBaseFragment;
import heima3_2.cn.osc.base.OurTabBasePresenter;
import heima3_2.cn.osc.model.bean.MessagesBean;
import retrofit2.Call;
import retrofit2.Response;

/**
 * Created by yaozhanlie on 2017/1/18.
 */

public class LeavePresenter extends OurTabBasePresenter<MessagesBean, MessagesBean.MessageBean> {

    public LeavePresenter(OurTabBaseFragment ourTabBaseFragment) {
        super(ourTabBaseFragment);
    }

    @Override
    protected void doRetrofitQuest() {
        Call<MessagesBean> login = mRetrofitInterface.getLeaveInfo(3231178, 0, 20);
        login.enqueue(mCallback);
    }

    @Override
    public List<MessagesBean.MessageBean> getDataBean(Response<MessagesBean> response) {
        return response.body().getMessages();
    }
}
